package com.leetcode.practice.self.listen;

import com.leetcode.practice.self.entity.UserDomain;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.ApplicationEventPublisher;
import org.springframework.context.ApplicationListener;
import org.springframework.stereotype.Component;

import java.time.LocalDateTime;
import java.util.UUID;

@Component
@Slf4j
public class ListenerPublisherImpl implements ListenerPublisher{

    @Autowired
    private ApplicationEventPublisher applicationEventPublisher;

    @Override
    public void pushBaseEvent(BaseEvent baseEvent) {
        applicationEventPublisher.publishEvent(baseEvent);
    }
}
